package com.javatest;

public class Test {
    public static void main(String[] args) {
       /* RunTest runTest= new RunTest("老年人",1000,1);
        RunTest runTest1=  new RunTest("年轻人",200,2);
        runTest.start();
        runTest1.start();*/

       /* Thread thread = new Thread(new MasterDock(),"");
        thread.setPriority(Thread.MAX_PRIORITY);
        thread.start();
        //主线程模拟医院叫号
        for(int i=0;i<20;i++){
            System.out.println("普通号："+(i+1)+"号病人在看病..");
            try {
               Thread.sleep(500);
                if(i==9){
                    thread.join();
                }
            }catch (Exception e){
                e.printStackTrace();
            }
        }*/

        Ticketing ticketing = new Ticketing();
        Thread thread = new Thread(ticketing,"黄涛涛");
        Thread thread1 = new Thread(ticketing,"李明");
        Thread thread2 = new Thread(ticketing,"赵思思");
        thread.start();
        thread1.start();
        thread2.start();

    }
}
